Refactor FXIOS-12796 [Swift 6 Migration] Fix main actor isolation warnings that are Swift 6 errors in the XCUITests suite - Batch 2#12
Open
Refactor FXIOS-12796 [Swift 6 Migration] Fix main actor isolation warnings that are Swift 6 errors in the XCUITests suite - Batch 2#12
Conversation
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.
| continueAfterFailure = false | ||
| setUpExperimentVariables() | ||
| setUpApp() | ||
| setUpExperimentVariables() |
There was a problem hiding this comment.
Method call order swapped causes nil unwrap crash
High Severity
The order of setUpApp() and setUpExperimentVariables() has been accidentally swapped during refactoring. setUpApp() calls addLaunchArgument(jsonFileName: jsonFileName, featureName: featureName), which requires these implicitly unwrapped optionals (String!) to be set first. Since setUpExperimentVariables() is now called after setUpApp(), accessing the nil values will cause a runtime crash.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Benchmark PR from qodo-benchmark#240
Note
Refactors the XCUITest suite for Swift 6 concurrency and main-actor safety.
setUp/tearDownacross Base and all test classes toasync throws, invokingtry await super.setUp()/tearDown(); adjust platform-specific subclasses accordingly@MainActorto UI-bound globals, helpers, screen graph/navigation registration functions, and utilities (e.g.,BaseTestCaseglobals, Today Widget selectors, navigation helpers,A11yUtils,FxScreenGraphfiles)FeatureFlaggedTestBase.setUp()call order, launch arguments placement) and small cleanups; no functional test logic changes intendedWritten by Cursor Bugbot for commit 5d69751. Configure here.